<include file="Public:header" />
<body class="gray-bg">
<div class="wrapper wrapper-content">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>全局配置</h5>
                </div>
                <div class="ibox-content">
                    <div class="panel blank-panel">
                        <div class="panel-heading">
                            <div class="panel-options">
                                <ul class="nav nav-tabs">
                                    <li class="active"><a data-toggle="tab" href="{:U('index')}#A">站点设置</a>
                                    </li>
                                    <li class=""><a data-toggle="tab" href="{:U('index')}#B">后台登录设置</a>
                                    </li>
                                    <li class=""><a data-toggle="tab" href="{:U('index')}#C">短信设置</a>
                                    </li>
                                    <li class=""><a data-toggle="tab" href="{:U('index')}#D">邮箱设置</a>
                                    </li>
                                    <li class=""><a data-toggle="tab" href="{:U('index')}#E">上传设置</a>
                                    </li>
                                </ul>
                            </div>
                        </div>
                        <form method="post" class="form-horizontal" name="myform" action="{:U('setting_post')}">
                            <input type="hidden" name="option_id" value="{$option_id}">
                        <div class="panel-body">
                            <div class="tab-content">
                                <div id="A" class="tab-pane active">
                                    <div class="row">
                                        <div class="col-sm-12">
                                            <div class="ibox">
                                                        <!-- 网站名称-->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">网站名称</label>
                                                            <div class="col-sm-5">
                                                                <input type="text" name="options[site_name]" class="form-control" value="{$site_name}">
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 网站关键字 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">网站关键字</label>

                                                            <div class="col-sm-5">
                                                                <input type="text" name="options[site_keywords]" class="form-control" value="{$site_keywords}">
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 网站简介 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">网站简介</label>

                                                            <div class="col-sm-5">
                                                                <textarea class="form-control" name="options[site_desp]">{$site_desp}</textarea>
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 网站备案 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">网站备案</label>

                                                            <div class="col-sm-5">
                                                                <input type="text" name="options[site_icp]" class="form-control" value="{$site_icp}">
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 站长邮箱 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">站长邮箱</label>

                                                            <div class="col-sm-5">
                                                                <input type="text" name="options[site_email]" class="form-control" value="{$site_email}">
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 网站统计代码 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">统计代码</label>

                                                            <div class="col-sm-5">
                                                                <textarea class="form-control" name="options[site_code]">{$site_code}</textarea>
                                                                <span class="help-block m-b-none">可将第三方提供的网站访问统计HTML代码，直接粘贴到此次即可统计全站</span>
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 版权信息 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">版权信息</label>

                                                            <div class="col-sm-5">
                                                                <textarea class="form-control" name="options[site_copright]">{$site_copright}</textarea>
                                                                <span class="help-block m-b-none">可以在此声明网站的版权信息等，也可以填写关于我们、联系我们等信息； 此次支持HTML代码，不用可以留空</span>
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 网站状态 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">网站状态</label>
                                                            <div class="col-sm-5">
                                                                <label class="radio-inline">
                                                                    <input type="radio" name="options[site_status]" value="1" {$site_status==1?'checked':''}> 开启
                                                                </label>
                                                                <label class="radio-inline">
                                                                    <input type="radio" name="options[site_status]"  value="0" {$site_status==0?'checked':''}> 关闭
                                                                </label>
                                                            </div>
                                                        </div>
                                                        <div class="hr-line-dashed"></div>
                                                        <!-- 网站关闭缘由 -->
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">网站关闭缘由：</label>

                                                            <div class="col-sm-5">
                                                                <textarea class="form-control" name="options[site_reason]">{$site_reason}</textarea>
                                                                <span class="help-block m-b-none"></span>
                                                            </div>
                                                        </div>
                                                        <!-- 按钮 -->
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div id="B" class="tab-pane">
                                    <div class="row">
                                        <div class="col-sm-12">
                                            <div class="ibox">
                                                <!-- 开启验证码 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">登录验证码</label>

                                                    <div class="col-sm-5">
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[site_verify]" value="1" {$site_verify==1? 'checked':''}> 开启
                                                        </label>
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[site_verify]"  value="0" {$site_verify==0? 'checked':''}> 关闭
                                                        </label>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 后台最大登录失败次数-->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">登录失败次数</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[site_max_error_login]" value="{$site_max_error_login}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 后台绑定域名-->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">后台绑定域名</label>

                                                    <div class="col-sm-5">
                                                        <input type="text" class="form-control" name="options[site_admin_url]" value="{$site_admin_url}">
                                                        <span class="help-block m-b-none">绑定后只能用此域名访问</span>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 前台禁止访问ip地址 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">前台禁止ip访问列表</label>

                                                    <div class="col-sm-5">
                                                        <textarea class="form-control" rows="5" name="options[site_font_baned_ip]">{$site_font_baned_ip}</textarea>
                                                    </div>
                                                    <div class="col-sm-5">
                                                        <span class="help-block m-b-none">当用户处于本列表中的 IP 地址时将无法访问本站点前台所有页面。 每个 IP 一行，既可输入完整地址，也可只输入 IP 开头，例如 "192.168."(不含引号) 可匹配 192.168.0.0～192.168.255.255 范围内的所有地址，留空为所有 IP 均可访问</span>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 后台禁止ip地址访问列表 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">后台禁止ip访问列表</label>

                                                    <div class="col-sm-5">
                                                        <textarea class="form-control" rows="5" name="options[site_back_baned_ip]">{$site_back_baned_ip}</textarea>
                                                    </div>
                                                    <div class="col-sm-5">
                                                        <span class="help-block m-b-none">只有当管理员处于本列表中的 IP 地址时才可以访问后台，列表以外的地址访问将无法访问，但仍可访问网站前端用户界面，请务必慎重使用本功能。 每个 IP 一行，既可输入完整地址，也可只输入 IP 开头，例如 "192.168."(不含引号) 可匹配 192.168.0.0～192.168.255.255 范围内的所有地址，留空为所有 IP 除明确禁止的以外均可访问系统</span>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div id="C" class="tab-pane">
                                    <div class="row">
                                        <div class="col-sm-12">
                                            <div class="ibox">
                                                <!-- 短信接口选择 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">短信接口</label>
                                                    <div class="col-sm-4">
                                                        <select class="form-control" name="options[sms_api]">
                                                            <option value="smsbao" {$sms_api=='smsbao'?'selected':''}>短信宝</option>
                                                            <option value="smscn" {$sms_api=='smscn'?'selected':''}>中国SMS</option>
                                                        </select>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 账户名 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">账户名</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[sms_account]" value="{$sms_account}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 密码 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">密 码</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[sms_password]" value="{$sms_password}">
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div id="D" class="tab-pane">
                                    <div class="row">
                                        <div class="col-sm-12">
                                            <div class="ibox">
                                                <!-- 邮件接口选择 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">邮件发送模式</label>
                                                    <div class="col-sm-4">
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[email_send_type]" value="1" {$email_send_type==1?'checked':''}> SMTP函数发送
                                                        </label>
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[email_send_type]"  value="0" {$email_send_type==0?'checked':''} > mail模块发送
                                                        </label>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 账户名 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">邮件服务器</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[email_server_name]" value="{$email_server_name}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 密码 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">邮件发送端口</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[email_server_port]" value="{$email_server_port}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 密码 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">发件人地址</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[email_server_sender]" value="{$email_server_sender}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">AUTH LOGIN验证</label>
                                                    <div class="col-sm-4">
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[email_auth_login]" value="1" checked> 开启
                                                        </label>
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[email_auth_login]"  value="0"> 关闭
                                                        </label>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">验证用户名</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[email_account]" value="{$email_account}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">验证密码</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[email_password]" value="{$email_password}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">邮件测试</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="address" id="address">
                                                    </div>
                                                    <div class="col-sm-4">
                                                        <button class="btn btn-warning " type="button">测试发送</button>
                                                    </div>
                                                </div>

                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div id="E" class="tab-pane">
                                    <div class="row">
                                        <div class="col-sm-12">
                                            <div class="ibox">
                                                <!-- 文件保存目录 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">文件保存根目录</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[attach_upload_dir]" value="{$attach_upload_dir}">
                                                    </div>
                                                    <div class="col-sm-4">
                                                        相对与根目录
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <!-- 图片路径设置 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">图片上传设置</label>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" placeholder="填写路径" name="options[attach_image_path]" value="{$attach_image_path}">
                                                    </div>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" placeholder="填写类型" name="options[attach_image_types]" value="{$attach_image_types}">
                                                    </div>
                                                    <div class="col-sm-3">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="填写大小限制" name="options[attach_image_size]" value="{$attach_image_size}">
                                                            <span class="input-group-addon">MB</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <!-- 文件上传设置 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">文件上传设置</label>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" placeholder="填写路径" name="options[attach_file_path]" value="{$attach_file_path}">
                                                    </div>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" placeholder="填写类型" name="options[attach_file_types]" value="{$attach_file_types}">
                                                    </div>
                                                    <div class="col-sm-3">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="填写大小限制" name="options[attach_file_size]" value="{$attach_file_size}">
                                                            <span class="input-group-addon">MB</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <!-- 多媒体路径设置 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">多媒体上传设置</label>
                                                    <div class="col-sm-3">
                                                            <input type="text" class="form-control" placeholder="填写路径" name="options[attach_media_path]" value="{$attach_media_path}">
                                                    </div>
                                                    <div class="col-sm-3">
                                                            <input type="text" class="form-control" placeholder="填写类型" name="options[attach_media_types]" value="{$attach_media_types}">
                                                    </div>
                                                    <div class="col-sm-3">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="填写大小限制" name="options[attach_media_size]" value="{$attach_media_size}">
                                                            <span class="input-group-addon">MB</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 是否开启压缩图片 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">对上传图片压缩</label>
                                                    <div class="col-sm-4">
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[image_compression]" value="1" {$image_compression==1?'checked':''}> 开启
                                                        </label>
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[image_compression]"  value="0" {$image_compression==0?'checked':''}> 关闭
                                                        </label>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <!-- 压缩图片大小限制 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">压缩图片大小限制</label>

                                                    <div class="col-sm-4">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="宽" name="options[image_compress_width]" value="{$image_compress_width}">
                                                            <span class="input-group-addon">px</span>
                                                        </div>
                                                    </div>
                                                    <div class="col-sm-4">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="高" name="options[image_compress_height]" value="{$image_compress_height}">
                                                            <span class="input-group-addon">px</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 开启图片水印 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">图片水印</label>
                                                    <div class="col-sm-4">
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[image_watermark]" value="1" {$image_watermark==1?'checked':''}> 开启
                                                        </label>
                                                        <label class="radio-inline">
                                                            <input type="radio" name="options[image_watermark]"  value="0" {$image_watermark==0?'checked':''}> 关闭
                                                        </label>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 水印添加条件 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印添加条件</label>
                                                    <div class="col-sm-4">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="宽" name="options[watermark_min_width]" value="{$watermark_min_width}">
                                                            <span class="input-group-addon">px</span>
                                                        </div>
                                                    </div>
                                                    <div class="col-sm-4">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" placeholder="高" name="options[watermark_min_height]" value="{$watermark_min_height}">
                                                            <span class="input-group-addon">px</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>

                                                <!-- 水印图片位置 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印图片位置</label>

                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[watermark_path]" value="{$watermark_path}">
                                                    </div>
                                                    <div class="col-sm-4">
                                                        路径相对于根目录
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 水印文字 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印文字</label>
                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[watermark_text]" value="{$watermark_text}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 文字大小 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">文字大小</label>
                                                    <div class="col-sm-2">
                                                        <div class="input-group">
                                                            <input type="text" class="form-control" name="options[watermark_fontsize]" value="{$watermark_fontsize}">
                                                            <span class="input-group-addon">px</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 文字颜色 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">文字颜色</label>
                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[watermark_fontcolor]" value="{$watermark_fontcolor}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 字体 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印字体</label>
                                                    <div class="col-sm-4">
                                                        <input type="text" class="form-control" name="options[watermark_fontfamily]" value="{$watermark_fontfamily}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 水印透明度 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印透明度</label>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" name="options[watermark_opacity]" value="{$watermark_opacity}">
                                                    </div>
                                                    <div class="col-sm-4">
                                                        从0到100，0表示不透明，100表示完全透明
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 水印质量 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印质量</label>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" name="options[watermark_quality]" value="{$watermark_quality}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 水印边距 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印边距</label>
                                                    <div class="col-sm-3">
                                                        <input type="text" class="form-control" name="options[watermark_margin]" value="{$watermark_margin}">
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <!-- 水印位置 -->
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">水印位置</label>
                                                    <div class="col-sm-5">
                                                        <table class="table table-bordered">
                                                            <tbody>
                                                                <tr>
                                                                    <td rowspan="3">
                                                                        <input class="radio_style" name="options[watermark_pos]" value="10" type="radio">随机位置
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="1" type="radio">顶部居左
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="2" type="radio">顶部居中
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="3" type="radio">顶部居右
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="4" type="radio">左部居中
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="5" type="radio">左部居左
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="6" type="radio">左部居右
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="7" type="radio">底部居左
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="8" type="radio">底部居中
                                                                    </td>
                                                                    <td>
                                                                        <input class="radio_style" name="options[watermark_pos]" value="9" type="radio">底部居右
                                                                    </td>
                                                                </tr>
                                                            </tbody>
                                                        </table>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="hr-line-dashed"></div>
                                <div class="form-group">
                                    <div class="col-sm-4 col-sm-offset-2">
                                        <button class="btn btn-primary" type="submit">保存设置</button>
                                    </div>
                                </div>
                            </div>
                        </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script>
    // 初始化
    $(document).ready(function(){
        // 设置最后一个的值
        var watermark_pos = "{$watermark_pos}";
        $("input[name='options[watermark_pos]'][value='"+watermark_pos+"']").attr("checked",'checked');


    });
    // 表单验证
    // ajax 提交
    // dialog表示是否成功
</script>
</body>
</html></body>
</html>